#!/bin/bash
## #######################################################################################
#
# Copyright (c) KylinSoft Co., Ltd. 2024. All rights reserved.
# SecureGuardian is licensed under the Mulan PSL v2.
# You can use this software according to the terms and conditions of the Mulan PSL v2.
# You may obtain a copy of Mulan PSL v2 at:
#     http://license.coscl.org.cn/MulanPSL2
# THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, EITHER EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, MERCHANTABILITY OR FIT FOR A PARTICULAR
# PURPOSE.
# See the Mulan PSL v2 for more details.
# Description: Security Baseline Check Script for 1.1.14
#
# #######################################################################################

source $(dirname $(realpath $0))/../utils.sh

set_sysctl "net.ipv4.conf.all.accept_redirects" "0"
set_sysctl "net.ipv6.conf.all.accept_redirects" "0"
set_sysctl "net.ipv4.conf.all.secure_redirects" "0"
set_sysctl "net.ipv4.conf.default.secure_redirects" "0"
set_sysctl "net.ipv4.conf.all.send_redirects" "0"
set_sysctl "net.ipv4.conf.default.send_redirects" "0"